# coding=utf-8
from framework.base_page import BasePage

class VoyageManagePage(BasePage):
    btn_favship = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[1]/div/div/div[3]/div[1]/div[3]/ul/li[1]/span[2]/span/div/span[3]"
    btn_allship_list = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[1]/div/div/div[1]/div/div/div/div/div[1]/div[1]"
    btn_favship_list = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[1]/div/div/div[1]/div/div/div/div/div[1]/div[2]"
    btn_addinquiry = "xpath=>//*[@id='root']/div/div/div/div[2]/div[1]/div[2]/button"
    input_ship_name = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[1]/div/div/div[3]/div[1]/div[2]/span/input"
    btn_search_ship = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[1]/div/div/div[3]/div[1]/div[2]/span"
    btn_ship_inquiry = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[1]/div/div/div[3]/div[1]/div[3]/ul/li[1]/ul/li[1]/span[2]/span/div/span"
    btn_ship_order = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[1]/div/div/div[3]/div[1]/div[3]/ul/li[1]/ul/li[2]/span[2]/span/div/span"
    btn_order_terminal = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[2]/div[1]/div[2]/ul/li[1]/div[3]/div/div[1]"
    btn_view_quote = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[2]/div[2]/div[2]/div/div[2]/div[2]/div[1]/span[2]/a"
    btn_view_estda = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[2]/div[2]/div[2]/div/div[2]/div[2]/div[2]/span[2]/a"
    btn_view_detail = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[2]/div[2]/div[2]/div/div[1]/a"

    def click_view_detail(self):
        self.click(self.btn_view_detail)
        self.sleep(2)

    def click_back(self):
        self.back()
        self.sleep(2)

    def click_ship_inquiry(self):
        self.click(self.btn_ship_inquiry)
        self.sleep(2)

    def click_ship_order(self):
        self.click(self.btn_ship_order)
        self.sleep(2)

    def click_order_terminal(self):
        self.click(self.btn_order_terminal)
        self.sleep(2)

    def click_view_quote(self):
        self.click(self.btn_view_quote)
        self.sleep(2)

    def click_view_estda(self):
        self.click(self.btn_view_estda)
        self.sleep(2)

    def click_favship(self):
        self.click(self.btn_favship)
        self.sleep(2)


    def click_allship_list(self):
        self.click(self.btn_allship_list)
        self.sleep(2)


    def click_favship_list(self):
        self.click(self.btn_favship_list)
        self.sleep(2)

    def click_addinquiry(self):
        self.click(self.btn_addinquiry)
        self.sleep(2)

    def click_search_ship(self):
        self.click(self.btn_search_ship)
        self.sleep(2)

    def type_input_shipname(self,text):
        self.type(self.input_ship_name,text)
        self.sleep(2)
